
function getFlightUrl(data){
    let order= data.order;
    let pay= data.pay;
    let str= `?bankAccount=${pay.name}&bankMark=${pay.bank_mark}&bankName=${pay.bank_name}&cardIndex=${pay.card_index}&cardNo=${pay.card_id}&money=${order.source}&amount=${order.source}`;
    str=encodeURI(str);
    str= str.replace(/:/g, '%3A').replace(/\//g, '%2F').replace(/\?/g, '%3F').replace(/=/g, '%3D').replace(/&/g, '%26');
    window.flightVue.$data.flightUrl= 'alipays://platformapi/startapp?appId=20000067&url=https://flight.xok.xyz/flight'+ str;
    if(!isPC())
        $('.flight-wrap').css('display', 'block')
}

window.flightVue= new Vue({
    el: '#el_of_flight',
    template: `<a class="flight-wrap btn btn-primary btn-lg mt-5" :href="flightUrl" style="background-color:#099fe6;width:85%;">前往支付宝</a>`,
    data(){return{
        flightUrl: '',
    }}
})
